//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package study.API.集合.set.HashSet;

import java.util.Objects;

public class HachSetStudent {
    private String name;
    private int age;

    public HachSetStudent() {
    }

    public HachSetStudent(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public String getName() {
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return this.age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String toString() {
        return "HachSetStudent{name = " + this.name + ", age = " + this.age + "}";
    }

    public boolean equals(Object o) {
        if (o != null && this.getClass() == o.getClass()) {
            HachSetStudent that = (HachSetStudent)o;
            return this.age == that.age && Objects.equals(this.name, that.name);
        } else {
            return false;
        }
    }

    public int hashCode() {
        return Objects.hash(new Object[]{this.name, this.age});
    }
}
